package org.learn.spring5.service;

import org.learn.spring5.dao.UserDao;

public class UserService {

    //创建userDao属性，生成set方法

    private UserDao userDao;

    public void setUserDao(UserDao userDao) {
        this.userDao = userDao;
    }

    public void userAdd() {
        //调用 userDao对象的userAdd方法
        System.out.println("service userAdd");
        userDao.userAdd();

    }
}
